<?php

namespace Laoha\Core\Sets;

use Encore\Admin\Widgets\Form;

class Upload extends Form
{
    /**
     * The form title.
     *
     * @var string
     */
	public $name = 'upload';
    public $title = '上传';


    /**
     * Build a form here.
     */
    public function form()
    {
		$this->data = require(config_path('sets/'.$this->name.'.php'));
		$this->action(admin_base_path('laoha/set').'?active='.$this->name);

        //以下为实际设置区
		$this->number('file_size', '文件上传大小限制')->help('0为不限制大小，单位：kb')->rules('required');
        $this->tags('file_ext', '允许上传的文件后缀')->help('多个后缀用逗号隔开，不填写则不限制类型')->rules('required');
        $this->number('image_size', '图片上传大小限制')->help('0为不限制大小，单位：kb')->rules('required');
        $this->tags('image_ext', '允许上传的图片后缀')->help('多个后缀用逗号隔开，不填写则不限制类型')->rules('required');
        $this->number('thumbnail_size', '缩略图尺寸');
		//结束设置
    }


}
